//
//  ReportViewController.m
//  e-nurse
//
//  Created by  on 10/10/12.
//  Copyright (c) 2012 __MyCompanyName__. All rights reserved.
//

#import "ReportViewController.h"
#import "CalendarViewController.h"

@interface ReportViewController ()

@end

@implementation ReportViewController
@synthesize calendarViewConotroller = _calendarViewConotroller;
@synthesize calendarViewContainer = _calendarViewContainer;

- (void)dealloc
{
    [super dealloc];
}

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
    }
    return self;
}

- (void)viewDidLoad
{
    [super viewDidLoad];
    
    self.calendarViewConotroller.calendarViewControllerDelegate = self;
    [self addChildViewController:self.calendarViewConotroller];

    [self.calendarViewContainer addSubview:self.calendarViewConotroller.view];
    CGRect rect = self.calendarViewConotroller.view.frame;
    self.calendarViewConotroller.view.frame = CGRectMake(0, 0, rect.size.width, rect.size.height);
}

- (void)viewDidUnload
{
    [super viewDidUnload];
    
    self.calendarViewConotroller = nil;
    self.calendarViewContainer = nil;
}

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
    return (interfaceOrientation == UIInterfaceOrientationPortrait);
}

- (void)calendarViewController:(CalendarViewController *)aCalendarViewController dateDidChange:(NSDate *)aDate
{
    
}

@end
